//
//  UIView+Common.m
//  artist
//
//  Created by laotang on 16/4/17.
//  Copyright © 2016年 viviyoo. All rights reserved.
//

#import "UIView+Common.h"

@implementation UIView (Common)

@end


@implementation UILabel (Common)


+ (instancetype)creatLabelWithText:(NSString *)text Font:(UIFont *)font textColor:(UIColor *)textColor textAlignment:(NSTextAlignment)textAliment{
    
    UILabel *label = [[UILabel alloc] init];
    label.text = text;
    label.font = font;
    label.textColor = textColor;
    label.textAlignment = textAliment;
    return label;
    
}
@end


@implementation UIButton (Common)
- (void)setButtonTitle:(NSString *)title buttonImageName:(NSString *)buttonImageName forState:(UIControlState)state{
    
    [self setTitle:title forState:state];
    [self setImage:[UIImage imageNamed:buttonImageName] forState:state];
}
- (void)setButtonTitle:(NSString *)title Image:(UIImage *)Image forState:(UIControlState)state{
    [self setTitle:title forState:state];
    [self setImage:Image forState:state];
}

@end